package com.shop.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Data;

import java.util.List;

@Data
@TableName("sp_permission")
public class Right {
    @TableId(value = "ps_id", type = IdType.AUTO)
    private Integer id;
    @TableField("ps_name")
    private String authName;
    @TableField("ps_level")
    private String level;
    @TableField("ps_pid")
    private Integer pid;
    @JsonInclude(JsonInclude.Include.ALWAYS)
    @TableField(exist = false)
    private String path;

    @TableField(exist = false)
    private List<Right> children;
}
